import BasicLayout from '@/layouts/basic-layout'

const meta = {
  auth: true
}

const pre = 'home_'

export default {
  path: '/admin',
  name: 'home',
  header: 'home',
  redirect: {
    name: `${pre}index`
  },
  meta,
  component: BasicLayout,
  children: [{
      path: 'home',
      name: `${pre}index`,
      meta: {
        auth: ['admin-index-index'],
        title: '主页'
      },
      component: () =>
        import ('@/pages/index/panel')
    },
    {
      path: 'panel',
      name: `${pre}panel`,
      meta: {
        auth: ['admin-panel'],
        title: '系统主页'
      },
      component: () =>
        import ('@/pages/index/index')
    },
    {
      path: 'notice',
      name: `${pre}notice`,
      meta: {
        auth: ['admin-notice'],
        title: '通知公告'
      },
      component: () =>
        import ('@/pages/index/notice')
    },
    {
      path: 'notice_content',
      name: `${pre}notice_content`,
      meta: {
        title: '公告详情'
      },
      component: () =>
        import ('@/pages/index/noticeContent')
    },
  ]
}